package org.principles.demo3.bedore;

/**
 * 依赖倒转原则（错误）
 */
public class ComputerDemo {
    public static void main(String[] args) {
        Computer computer = new Computer();
        XiJieHardDisk disk = new XiJieHardDisk();
        IntelCpu cpu = new IntelCpu();
        KingstonMemory memory = new KingstonMemory();

        computer.setCpu(cpu);
        computer.setDisk(disk);
        computer.setMemory(memory);

        computer.run();
    }
}
